<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>功能主页面</title>
<link rel="stylesheet" type="text/css" href="themes/bootstrap/easyui.css">   
<link rel="stylesheet" type="text/css" href="themes/icon.css"> 
<link rel="stylesheet" type="text/css" href="themes/color.css">  
<script type="text/javascript" src="js/jquery-1.11.1.min.js"></script>   
<script type="text/javascript" src="js/jquery.easyui.min.js"></script> 
<script type="text/javascript" src="js/easyui-lang-zh_CN.js"></script>
</head>
<script>
$(function(){
	$('#tt').tree({    
	    url:'loadFuncsTree',
	    queryParams:{
	    	pid:-1
	    },
	    onLoadSuccess:function(node,data){
	    	$("#tt").tree('expandAll')
	    },
	    onClick:function(node){
	    	var  flag = $("#tb").tabs('exists',node.text)
	    	if(node.attributes.url){
	    		if(!flag){
		    		$("#tb").tabs('add',{
			    		title:node.text,
			    		content:"<iframe  width='100%' height='100%' frameborder='0' src='"+node.attributes.url+"'></iframe>",
			    		closable:true
			    	})	
		    	}else{
		    		$("#tb").tabs('select',node.text)

		    	}
	    	}
	    	
	    	
	    }
	});
	 
})
</script>
<body class="easyui-layout">
<div style="background-image:url(img/eee.png);height:120px;" data-options="region:'north',split:false" ></div>   
<div data-options="region:'west',title:'欢迎你',split:false" style="width:220px;">
<ul id="tt"></ul> 
</div>   
<div data-options="region:'center'" style="padding:5px;background:#eee;">
<div id="tb" class="easyui-tabs" data-options="fit:true,border:false">   
</div>  
</div> 
</body>
</html>